#include<stdio.h>
#include<string.h>
#include<stdlib.h>
#include<time.h>

void print_arr(int*, int, int);
void suffixArray(int* , int*, int , int ) ;
void radixPass(int* , int* , int* , int , int ); 
void merge_suffixes(int *, int *, int *, int *, int *, int, int, int, int);
int CPU_left_boundary(int* , int , char* , char* );
int CPU_right_boundary(int* , int , char* , char* );
void trans_querySeq_to_digits(char*, int*);
inline int leq(int a1, int a2, int b1, int b2); 
inline int leq2(int a1, int a2, int a3, int b1, int b2, int b3);
void read_genome(char *filename, char *buffer, int num);
int to_i(char c);
void print_suffix(char *cc, int i);
int set_suffix_rank(int *orig_str, int *set_rank_arr, int *sorted_suff_arr, int n02, int n0);

#define MAX_ALPHA 26

#define GetI() (SA12[t] < n0 ? SA12[t] * 3 + 1 : (SA12[t] - n0) * 3 + 2)

